<?php

namespace App\Http\Controllers;

use App\Lib\ConsumerTest;
use Illuminate\Http\Request;

use App\Lib\Publisher;

class IndexController extends Controller
{
    public function index(Request $request)
    {
        $params = $request->post();
        $p = Publisher::getInstance();
        $p->requestData = $params;
        $ret = $p->publisher();
        return json_encode($ret, JSON_UNESCAPED_UNICODE);

        /*$p = new ConsumerTest();
        $ret = $p->consumer();
        return $ret;*/
    }
}